﻿using Core.Graphics;
using Core.Objects;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Core.Physics
{
    public class SimplePhysEngine : Engine
    {
        public SimplePhysEngine(GraphEngine graph)
            : base(graph)
        {

        }

        public override void ProcessKey(InputSignal signal)
        {
            if (Vehicle is Helicopter)
            {
                Vehicle.Move(signal);
            }
            else
            {
                switch (signal)
                {
                    /*  case InputSignal.FORWARD:
                      case InputSignal.BACK:
                      case InputSignal.RIGHT:
                      case InputSignal.LEFT:
                      case InputSignal.UP:
                      case InputSignal.DOWN:
                      case InputSignal.ROTATE_CLOCKWISE:
                      case InputSignal.ROTATE_COUNTERCLOCKWISE:
                      case InputSignal.FLY_BY_CLOCKWISE:
                      case InputSignal.FLY_BY_COUNTERCLOCKWISE:
                      case InputSignal.NONE:
                      case InputSignal.DOWN_PARALLEL:
                      case InputSignal.UP_PARALLEL:*/
                    case InputSignal.SHOT:
                        Vehicle.Shot();
                        break;
                    case InputSignal.LOOK_UP:

                        break;
                    case InputSignal.LOOK_DOWN:

                        break;
                    default:
                        UpdateAcceleration(signal);
                        break;
                }

            }
        }

        protected override void UpdateAcceleration(InputSignal signal)
        {

        }
    }
}
